/*文件注释
 * ===============================================================================
 * 说明：
 * 作者：zengyy
 * 版本：v1.0
 * 创建日期：2013-06-01 22:29:57
 * 完成日期： 
 * 修改纪录：  
 * ===============================================================================
 */
using System;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using SRF.Common.Validation;

namespace SRF.Admin.Models
{
    ///<summay>
    /// 字典项
    ///</summay>
    [Serializable]
    public class DictionaryItem
    {
        #region 属性

        /// <summary>
        /// 
        /// </summary> 
        [DisplayName("Id")]
        public string Id { get; set; }
        /// <summary>
        /// 编码
        /// </summary>
        [StringLength(50)]
        [Required(ErrorMessage = "请输入编码")]
        [DisplayName("编码")]
        public string Code { get; set; }
        /// <summary>
        /// 名称
        /// </summary>
        [StringLength(300)]
        [Required(ErrorMessage = "请输入名称")]
        [DisplayName("名称")]
        public string Text { get; set; }
        /// <summary>
        /// 所属字典id
        /// </summary>
        [StringLength(38)]
        [Required(ErrorMessage = "请输入所属字典id")]
        [DisplayName("所属字典id")]
        public string DictionaryId { get; set; }
        /// <summary>
        /// 排序 
        /// </summary>
        [DataTypeValidator(DataTypePattern.Integer)]
        [Required(ErrorMessage = "请输入排序")]
        [DisplayName("排序 ")]
        public int Rank { get; set; }
        /// <summary>
        /// 描述
        /// </summary>
        [StringLength(250)]
        [DisplayName("描述")]
        public string Remark { get; set; }
        /// <summary>
        /// 有效 
        /// </summary>

        [DisplayName("有效 ")]
        public bool Enabled { get; set; }

        #endregion
    }
}


